package br.usp.icmc.biomac.client.view.lixo;

import com.google.gwt.core.client.GWT;
import com.google.gwt.uibinder.client.UiBinder;
import com.google.gwt.user.client.ui.Composite;
import com.google.gwt.user.client.ui.Widget;
import com.google.gwt.uibinder.client.UiField;
import com.google.gwt.user.client.ui.FlexTable;

public class AttributesTableTab extends Composite {

	private static AttributesTableTabUiBinder uiBinder = GWT
			.create(AttributesTableTabUiBinder.class);
	@UiField FlexTable header;
	@UiField FlexTable table;

	interface AttributesTableTabUiBinder extends
			UiBinder<Widget, AttributesTableTab> {
	}

	public AttributesTableTab() {
		initWidget(uiBinder.createAndBindUi(this));
		initTable();
	}

	/**
	 * ROIS. 
	 */
	private void initTable() {
		/*// Initialize the header.
		header.getColumnFormatter().setWidth(0, "25px");
		header.getColumnFormatter().setWidth(1, "25px");*/

		header.setText(0, 0, "Attributes");
		header.setText(0, 1, "Values");
		//header.getCellFormatter().setHorizontalAlignment(0, 3,HasHorizontalAlignment.ALIGN_RIGHT);

		/*// Initialize the table.
		table.getColumnFormatter().setWidth(0, "25px");
		table.getColumnFormatter().setWidth(1, "25px");*/
		for (int i=0; i<40; i++){
			for (int y=0; y<2; y++){
				table.setText(i, y, "Text " + Integer.toString(i));
			}
		}
	}
}
